package com.cainli.szbus.data.model;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * result_num int 结果数量 
 * web_url string 爱帮web站对应url 
 * wap_url string 爱帮wap站对应url
 * name string 线路名称 
 * info string 线路信息 包括线路类型、票价、首末班车时间等 
 * stats string 沿途站点 半角分号;(英文分号)分隔 
 * stat_xys string 途径站点经纬度 经度与纬度用半角逗号,(英文逗号)分隔；
 * 		每组经纬度用半角分号;(英文分号)分隔
 * xys string 线路坐标 线路本身对应的各个坐标点，经度与纬度用半角逗号,
 * 		(英文逗号)分隔；每组经纬度用半角分号;(英文分号)分隔
 * 
 * @author cainli
 */
public class BusLine implements Parcelable {
	public String name;
	public String info;
	public String stats;
	public String stat_xys;
	public String xys;
	public BusLine() {
	}

	private BusLine(Parcel in) {
		name = in.readString();
		info = in.readString();
		stats = in.readString();
		stat_xys = in.readString();
		xys = in.readString();
	}

	@Override
	public int describeContents() {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(name);
		dest.writeString(info);
		dest.writeString(stats);
		dest.writeString(stat_xys);
		dest.writeString(xys);
	}

	public static final Parcelable.Creator<BusLine> CREATOR = new Parcelable.Creator<BusLine>() {

		@Override
		public BusLine createFromParcel(Parcel source) {
			return new BusLine(source);
		}

		@Override
		public BusLine[] newArray(int size) {
			return new BusLine[size];
		}
	};
	@Override
	public String toString() {
		return "BusLine [name=" + name + ", info=" + info + ", stats=" + stats
				+ ", stat_xys=" + stat_xys + ", xys=" + xys + "]";
	}
}
